﻿using Microsoft.Extensions.DependencyInjection;

namespace Leo.Common.RabbitMQ
{
    public class RabbitBuilder
    {

        private readonly IServiceCollection services;

        /// <summary>
        /// 禁用消费者
        /// </summary>
        private bool disableConsumer;

        /// <summary>
        /// 队列集合
        /// </summary>
        internal readonly List<RabbitQueueInfo> Queues = new List<RabbitQueueInfo>();

         
        private readonly List<RabbitObjectBase> deleteObjects = new List<RabbitObjectBase>();

        public List<MQConsumerBase> Consumers { get; set; } = new List<MQConsumerBase>();


        //internal RabbitProducer Producer { get; private set; }

        public RabbitConfig Config { get; set; }
         
        public RabbitConnection Connection { get; set; }

        public RabbitBuilder(RabbitConfig config, IServiceCollection services)
        {
            this.Config = config;
            this.services = services;
            this.Connection = new RabbitConnection(config);
        }




    }
}
